put "Welcome to Lunar Lander. Please click on one of the buttons" & " below to begin. Click " & quote & "Instructions" & quote & " if you've never played before." into cd fld "info"
hide message
show menuBar
pass openCard
end openCard
-- part 7 (field)
-- low flags: 01
-- high flags: 2001
-- rect: left=15 top=111 right=199 bottom=217
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 0
-- font id: 3
-- text size: 12
-- style flags: 8192
-- line height: 16
-- part name: Info
-- part 9 (button)
-- low flags: 80
-- high flags: 8000
-- rect: left=257 top=279 right=333 bottom=316
-- title width / last selected line: 0
-- icon id / first selected line: 9479 / 9479
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Lunar Lander
----- HyperTalk script -----
on mouseUp
visual effect zoom open
go to stack "Lunar Lander"
end mouseUp
-- part 12 (button)
-- low flags: 00
-- high flags: 8004
-- rect: left=231 top=279 right=334 bottom=298
-- title width / last selected line: 0
-- icon id / first selected line: 7591 / 7591
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Instructions
----- HyperTalk script -----
on mouseUp
hide message
hide menuBar
visual effect scroll right
go last
end mouseUp
-- part 8 (button)
-- low flags: 00
-- high flags: 8004
-- rect: left=301 top=279 right=335 bottom=367
-- title width / last selected line: 0
-- icon id / first selected line: 21837 / 21837
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Install Button
----- HyperTalk script -----
on mouseUp
answer "This will easily install a button in your home stack to launch " & "Lunar Lander. Do you wish to install this button " & "in your home stack?" with "Cancel" or "Install"
if it is not "install" then exit mouseUp
set the cursor to watch
lock screen
show card button "Lunar Lander"
select card button "Lunar Lander"
doMenu "copy button"
hide card button "Lunar Lander"
go home
unlock screen
put the loc of message into locHolder
set the loc of message to 15,10
put "Move the button to the desired location and click"
set the cursor to none
doMenu "Paste button"
repeat while the mouse is not "down"
set the loc of card button "Lunar Lander" to the mouseLoc
end repeat
choose browse tool
put ""
hide message
set the loc of message to locHolder
send mouseUp to card button "Lunar Lander"
end mouseUp
-- part 6 (button)
-- low flags: 00
-- high flags: 8004
-- rect: left=161 top=279 right=334 bottom=228
-- title width / last selected line: 0
-- icon id / first selected line: 23961 / 23961
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Start
----- HyperTalk script -----
on mouseUp
global groundY
put return & "Please stand by:" & return & "Now creating lunar landscape..." into cd fld "info"
set the cursor to busy
hide menuBar
lock screen
set the cantmodify of this stack to false
set the userlevel to 5
set the cursor to busy
go next
set the cursor to busy
choose select tool
doMenu "Select All"
doMenu "Clear Picture"
put 270 into groundY
set the cursor to busy
put false into pad
choose line tool
set lineSize to 1
set pattern to 12
put 1 into count
repeat
set the cursor to busy
add 1 to count
if count > 53 then exit repeat
put item count - 1 of groundY into item count of groundY
add the random of 30 - 15 to item count of groundY
if item count of groundY > 340 then put 340 into item count of groundY
drag from 10 * (count - 2), item count - 1 of groundY to 10 * (count - 1),item count of groundY
if count > 30 and the random of 3 = 1 and pad is not true then
set the visible of cd btn "pad" to true
set the hilite of cd btn "pad" to true
repeat with loop = 1 to 4
put item count of groundY into item count + loop of groundY
end repeat
drag from 10 * (count - 1),item count of groundY to 10 * (count + 3),item count of groundY
set the loc of cd btn "pad" to 10 * count + 10, item count of groundY + 1
add 4 to count
put true into pad
end if
end repeat
set the cursor to watch
choose bucket tool
click at 1,340
doMenu "Select All"
doMenu "Darken"
choose bucket tool
set the pattern to 5
click at 1,340
doMenu "Select All"
doMenu "Invert"
doMenu "background"
doMenu "select"
doMenu "copy picture"
doMenu "background"
doMenu "paste picture"
drag from 470,110 to 470 - the random of 400,110
choose browse tool
show cd btn "module"
set the icon of cd btn "module" to "module 0"
set the rect of cd btn "module" to 13,8,47,53
hide cd btn "flag"
put "Computed landing area now flashing on lunar surface" into cd fld "message"
unlock screen with visual effect dissolve
send startPlay to card
end mouseUp
-- part 11 (button)
-- low flags: 00
-- high flags: 8004
-- rect: left=439 top=279 right=334 bottom=506
-- title width / last selected line: 0
-- icon id / first selected line: 1199 / 1199
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Home
----- HyperTalk script -----
on mouseUp
visual effect iris close
go home
end mouseUp
-- part 14 (button)
-- low flags: 00
-- high flags: 8004
-- rect: left=370 top=279 right=335 bottom=436
-- title width / last selected line: 0
-- icon id / first selected line: 1006 / 1006
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Mac Info
----- HyperTalk script -----
on mouseUp
hide message
hide menubar
visual effect scroll down
go to card "macs"
end mouseUp
-- part contents for card part 7
----- text -----
Welcome to Lunar Lander. Please click on one of the buttons below to begin. Click "Instructions" if you've never played before.